<% var pageLevelJS = { %>
<%include("/WEB-INF/views/btl/template/include/select2.html"){}%>
<script type="text/javascript">
var settings = {
		 modelDomainFlag:"sys"
		 ,modelName:"邮件模板"
		 ,modelFlag:"emailTemplate"
		 ,key:"${sessionId}" 
		}
</script> 
<script type="text/javascript" src="${ctx}/static/js/sys/emailTemplate/edit.js"></script>
<%};%> 
<% var layoutParas =
{"title":"","add":isEmpty(data.id),"formId":"applyeditForm","pageLevelJS":pageLevelJS};
layout("/WEB-INF/views/btl/template/backBasicEditFormTemplate.html", layoutParas){ %>
	<input type="hidden" name="id" value="${data.id}">
	<div class="form-group  col-md-5">
       <label for="name" class="required-before col-sm-3 control-label no-padding-right">名称:</label>
       <div class="col-sm-9 inline-height ">
			  <input type="text" oldval="${data.name}" value="${data.name}" class="validate[required,maxSize[50]] col-xs-10" name="name" placeholder="名称" />
 	    </div> 
   </div>
   <div class="form-group  col-md-5">
       <label for="name" class="required-before col-sm-3 control-label no-padding-right">标题:</label>
       <div class="col-sm-9 inline-height ">
			  <input type="text" oldval="${data.subject}" value="${data.subject}" class="validate[required,maxSize[50]] col-xs-10" name="subject" placeholder="标题" />
 	    </div> 
   </div>
   <div class="form-group  col-md-5">
       <label for="name" class="required-before col-sm-3 control-label no-padding-right">模板路径:</label>
       <div class="col-sm-9 inline-height ">
			  <input type="text" oldval="${data.templateUrl}" value="${data.templateUrl}" class="validate[required,maxSize[50]] col-xs-10" name="templateUrl" placeholder="模板路径" />
 	    </div> 
   </div>
   <div class="form-group col-md-5">
	     <label class="required-before col-sm-3 control-label no-padding-right" for="categoryCode">模板类别:</label>
		 <div class="col-sm-9 inline-height ">
		   <select placeholder="模板类别" name="categoryCode" oldval="${data.categoryCode}" class="validate[required] col-xs-10">
				<% for(res in emailTypeFlags!){ %>
				  <option value="${res.id}"
				   <%if(data.categoryCode==res.code){%>
					  selected="selected"
					 <%}%>
				  >${res.message}</option>
			　　   <% } %>
			</select>
	  	 </div>
	  </div>
   <div class="form-group col-md-5">
	     <label class="required-before col-sm-3 control-label no-padding-right" for="emailboxId">发送邮箱:</label>
		 <div class="col-sm-9 inline-height ">
		   <select placeholder="发送邮箱" name="emailboxId" class="validate[required] col-xs-10"oldval="${data.emailboxId}" >
				<% for(res in emailboxFlags!){ %>
				  <option value="${res.id}"
				   <%if(data.emailboxId==res.id){%>
					  selected="selected"
					 <%}%>
				  >${res.name}</option>
			　　   <% } %>
			</select>
	  	 </div>
	  </div>
	  <div class="form-group col-md-5">
	     <label for="remark" class="col-sm-3 control-label no-padding-right">备注:</label>
	     <div class="col-sm-9 inline-height">
		    <input type="text"  oldval="${data.remark}" value="${data.remark}" class="validate[maxSize[50]] col-xs-10" name="remark" placeholder="备注">
		  </div>
	  </div>	 	 
<%} %>
